GXPrintingEvent
You must install an override function that QuickDraw GX invokes in response to thegxPrintingEvent
message. Your override must match the following formal declaration:
OSErr MyPrintingEvent (EventRecord *anEventRecord, Boolean filterEvent);
anEventRecord
- A pointer to an event that occurred in a print dialog box.
filterEvent
- A Boolean value that is
true
if the event needs to be filtered, andfalse
if not.- function result
- An error code. The value
noErr
indicates that the operation was successful.DESCRIPTION
QuickDraw GX sends thegxPrintingEvent
message whenever a specific event occurs in one of the print dialog boxes that is displayed for printing. You can override thegxPrintingEvent
message to handle events, such as window update events, that occur during display of print dialog boxes. You cannot name your function GXPrintingEvent.The default implementation of this message does nothing. You must override this message to correctly support print dialog boxes.
The
anEventRecord
parameter is a pointer to the event record. The event record contains information about what type of event occurred (a mouse-down, update, or key-down event, for example) and contains additional information associated with the event (for example, for a key-down event, the Event Manager also reports which key was pressed).SPECIAL CONSIDERATIONS
You never send thegxPrintingEvent
message yourself.You typically create a total override of the
gxPrintingEvent
message.RESULT CODES
gxSegmentLoadFailedErr A required code segment could not be found, or there was not enough memory to load it. gxPrUserAbortErr The user has canceled printing. SEE ALSO
Overriding thegxPrintingEvent
message is described in "Supporting QuickDraw GX Print Dialog Boxes," which begins on page 2-17.The
GXInstallApplicationOverride
function is described on page 2-71.The Event Manager, the
EventRecord
data type, and theDialogSelect
function are discussed in the chapter "Event Manager" in Inside Macintosh: Macintosh Toolbox Essentials.
Main | Page One | What's New | Apple Computer, Inc. | Find It | Contact Us | Help